package bank.model.dao.factory;

import bank.model.dao.*;

public abstract class AbstractDAOFactory {
	public static final int MYSQL_DAO = 1;
	
	public abstract AccountDAO getAccountDAO();
	public abstract ClientDAO getClientDAO();
	public abstract DepartmentDAO getDepartmentDAO();
	public abstract EmployeeDAO getEmployeeDAO();
	public abstract PaymentDAO getPaymentDAO();
	
	public static AbstractDAOFactory getDAOFactory(int certainfactory) throws Exception {
		if (certainfactory == MYSQL_DAO)
			return new MySqlDAOFactory();
		throw new Exception("DAO factory is not found. Good luck!");
	}
}
